// Copyright (c) 2020 Presto Labs Pte. Ltd.
// Author: linchuan

#pragma once

#include <memory>
#include <string>
#include <string_view>

#include "coin2/exchange/base/order/order.h"
#include "coin2/exchange/okex_v5_futures/api_order/native_private_client.h"

namespace coin2::exchange::okex_v5_futures::api_order {

class OkexV5FuturesRestAsyncAsioSubscriber : public base::order::RestSubscriber {
 public:
  using RestClient = OkexV5FuturesNativePrivateClient;
  using RestParams = OkexV5FuturesNativePrivateClient::RestParams;

 public:
  using RestSubscriber::RestSubscriber;
  auto rest_client() { return dynamic_cast<RestClient*>(rest_client_); }
  void QueryBalance();
  void QueryFundBalance();
  void QueryPosition();
  void QueryOpenOrders(std::string_view after_order_id);
  void QueryFinishedOrders();
  void QueryFills();
  void QueryTransfer();
  void QueryFundingFee();
  void SubscribeAsync() override;
};

}  // namespace coin2::exchange::okex_v5_futures::api_order
